<template>
  <div id="app">
    <Index v-if="zujian=='xiaoshuo'" @set="get" />
    <Tousu v-else-if="zujian=='tousu'" @set="get" />
    <Tousu2 v-else-if="zujian=='tousu2'" @set="get" />
    <Tijiao v-else @set="get" />
  </div>
</template>

<script>
import Index from './components/index.vue'
import Tousu from "./components/tousu/tousu";
import Tousu2 from "./components/tousu/tousu2";
import Tijiao from "./components/tousu/tijiao";

export default {
  name: 'app',
  data(){
    return{
      zujian: 'xiaoshuo'
    }
  },
  components: {
    Tijiao,
    Tousu2,
    Tousu,
    Index
  },
  methods:{
    get:function(msg){
      if(msg == 'tousu'){
        this.zujian = 'tousu'
      }else if(msg == 'tousu2'){
          this.zujian = 'tousu2'
      }else if(msg == 'tijiao'){
        this.zujian = 'tijiao'
      }else{
        this.zujian = 'xiaoshuo'
      }
    }
  }
}
</script>

<style>
#app {
  font-family: 'Avenir', Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
  body{
    margin: 0px;
  }
</style>
